package com.wlcorp.forcazamis.domain.confirm;

import java.util.Date;
import java.util.Set;

import com.wlcorp.forcazamis.domain.system.Staff;
import com.wlcorp.forcazamis.sys.BaseBean;
import com.wlcorp.forcazamis.sys.util.AppConstant;

public class Confirm extends BaseBean {
	private static final long serialVersionUID = 5677921429223108919L;
	private Long confirmId;
	private Integer confirmType;
	private Date submitTime;
	private Long submiterId;
	private Staff submiter;
	private Long itemId;
	private Integer state;
	private Integer result;
	private Long nextConfirmerId;
	private Staff nextConfirmer;
	private Set<?> confirmDetailSet;
	private boolean deleteFlag;

	public boolean isDeleteFlag() {
		return deleteFlag;
	}

	public void setDeleteFlag(boolean deleteFlag) {
		this.deleteFlag = deleteFlag;
	}

	private Integer noState;

	public Long getConfirmId() {
		return confirmId;
	}

	public void setConfirmId(Long confirmId) {
		this.confirmId = confirmId;
	}

	public Integer getConfirmType() {
		return confirmType;
	}

	public void setConfirmType(Integer confirmItem) {
		this.confirmType = confirmItem;
	}

	public Staff getSubmiter() {
		return submiter;
	}

	public void setSubmiter(Staff submiter) {
		this.submiter = submiter;
	}

	public Long getSubmiterId() {
		return submiterId;
	}

	public void setSubmiterId(Long submiterId) {
		this.submiterId = submiterId;
	}

	public Date getSubmitTime() {
		return submitTime;
	}

	public void setSubmitTime(Date submitTime) {
		this.submitTime = submitTime;
	}

	public Long getItemId() {
		return itemId;
	}

	public void setItemId(Long itemId) {
		this.itemId = itemId;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer result) {
		this.state = result;
	}

	public Set<?> getConfirmDetailSet() {
		return confirmDetailSet;
	}

	public void setConfirmDetailSet(Set<?> confirmDetailSet) {
		this.confirmDetailSet = confirmDetailSet;
	}

	public Integer getResult() {
		return result;
	}

	public void setResult(Integer result) {
		this.result = result;
	}

	public Staff getNextConfirmer() {
		return nextConfirmer;
	}

	public void setNextConfirmer(Staff nextConfirmer) {
		this.nextConfirmer = nextConfirmer;
	}

	public Long getNextConfirmerId() {
		return nextConfirmerId;
	}

	public void setNextConfirmerId(Long nextConfirmerId) {
		this.nextConfirmerId = nextConfirmerId;
	}

	public void setNoState(Integer noState) {
		this.noState = noState;
	}

	public Integer getNoState() {
		return noState;
	}

	public String getConfirmTypeName() {
		String confirmTypeName = "";
		if (AppConstant.CONFIRM_TYPE_IN_STORAGE == confirmType) {
			confirmTypeName = "入库单";
		} else if (AppConstant.CONFIRM_TYPE_OUT_STORAGE == confirmType) {
			confirmTypeName = "出库单";
		} else if (AppConstant.CONFIRM_TYPE_ASSIGN_STORAGE == confirmType) {
			confirmTypeName = "调拨单";
		} else if (AppConstant.CONFIRM_TYPE_PI == confirmType) {
			confirmTypeName = "销售合同";
		} else if (AppConstant.CONFIRM_TYPE_STOCK == confirmType) {
			confirmTypeName = "采购合同";
		}
		return confirmTypeName;
	}

	public String getResultName() {
		String resultName = "";
		if (AppConstant.CONFIRM_RESULT_NOT_PASS == confirmType) {
			resultName = "不通过";
		} else if (AppConstant.CONFIRM_RESULT_PASS == confirmType) {
			resultName = "通过";
		}
		return resultName;
	}
}
